<include file="../Public/header" />
<script data-main="__PUBLIC__/admin/js/page/admin/user/addusergroup" src="__PUBLIC__/admin/js/lib/requirejs/require.js"></script>
</head>

<body>
  <!-- 	<div id="breadcrumb">
	<if condition="isset($res)">
		<p class="fl">{$Think.lang.editor}{$Think.lang.userGroup}</p>
	<else/>
		<p class="fl">{$Think.lang.add}{$Think.lang.userGroup}</p>
	</if>
	</div> -->
  <if condition="isset($res)">
    <form action="{:URL('admin/User/editGroup')}" method="post">
      <else/>
      <form action="{:URL('admin/User/addGroup')}" method="post">
  </if>
  <div class="page">
    <div class="section">
      <div class="page-hd">
        <if condition="isset($res)">
          <h1>{$Think.lang.editor}{$Think.lang.userGroup}</h1>
          <else/>
          <h1>{$Think.lang.add}{$Think.lang.userGroup}</h1>
        </if>
      </div>
      <div class="tabitem">
        <div class="section-bd">
          <table>
            <tbody class="r1 r3">
              <input type="hidden" value="{$res.user_group_id}" name="id" />
              <tr>
                <td>
                  <label>{$Think.lang.name}：</label>
                </td>
                <td>
                  <input class="input-text" type="text" name="title" value="{$res.title}" />
                  <span class="remark" id="vaname"></span>
                </td>
              </tr>
            </tbody>
            <tbody>
              <tr>
                <td>
                  <label>{$Think.lang.pointsBetween}：</label>
                </td>
                <input type="hidden" value="{$res.max_credit}" name="hiddmaxcredit" />
                <td>
                  <input class="input-text" type="text" name="max_credit" value="{$res.max_credit}" onkeydown="KeyCodeOnlyNumber();" />
                </td>
              </tr>
            </tbody>
            <tbody>
              <tr>
                <td>
                  <label>{$Think.lang.star}{$Think.lang.num}：</label>
                </td>
                <td>
                  <input class="input-text" type="text" name="star" value="{$res.star}" onkeydown="KeyCodeOnlyNumber();" />
                </td>
              </tr>
            </tbody>
            <tbody>
              <tr>
                <td>
                  <label>{$Think.lang.icon}：</label>
                </td>
                <td>
                  <volist name="iconlist" id="i">
                    <input type='radio' name='icon' value='{$i.filename}' <php>if($i['filename'] == $res['icon']){</php>checked="checked"
                    <php>}</php>>
                    <img src="__PUBLIC__/icon/{$i.filename}">
                  </volist>
                </td>
              </tr>
            </tbody>
          </table>
        </div>
      </div>

      <div class="section-ft">
        <div class="actions">
          <if condition="isset($res)">
            <input class="btn2" style="*width: 145px;" type="submit" value="{$Think.lang.editor}{$Think.lang.userGroup}" />
            <else/>
            <input class="btn2" style="*width: 145px;" type="submit" value="{$Think.lang.add}{$Think.lang.userGroup}" />
          </if>
          <input class="btn2" type="button" value="{$Think.lang.cancel}" onclick="javascript:window.location.href='{:URL('admin/User/userGroup')}'" />
        </div>
      </div>
    </div>
  </div>
  </form>
</body>

</html>
